package co.yixiang.yshop.module.crm.controller.admin.crmclues.vo;

import com.alibaba.excel.annotation.ExcelProperty;
import com.alibaba.excel.annotation.format.DateTimeFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.time.LocalDateTime;
import java.util.Set;

/**
 * 专门用于线索数据导出的 VO 类
 * 支持动态列导出
 */
@Data
public class CrmCluesExportVO {

    @Schema(description = "ID")
    @ExcelProperty("ID")
    private Long id;

    @Schema(description = "线索姓名")
    @ExcelProperty("线索姓名")
    private String name;

    @Schema(description = "手机")
    @ExcelProperty("手机")
    private String mobile;

    @Schema(description = "电话")
    @ExcelProperty("电话")
    private String telephone;

    @Schema(description = "状态")
    @ExcelProperty("状态")
    private String status;

    @Schema(description = "转成客户ID")
    @ExcelProperty("转成客户ID")
    private Long customerId;

    @Schema(description = "转客户时间")
    @ExcelProperty("转客户时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime changeTime;

    @Schema(description = "客户级别")
    @ExcelProperty("客户级别")
    private String level;

    @Schema(description = "客户行业")
    @ExcelProperty("客户行业")
    private String industry;

    @Schema(description = "客户标签")
    @ExcelProperty("客户标签")
    private String tags;

    @Schema(description = "客户来源")
    @ExcelProperty("客户来源")
    private String source;

    @Schema(description = "备注")
    @ExcelProperty("备注")
    private String remark;

    @Schema(description = "负责人")
    @ExcelProperty("负责人")
    private String ownerName;

    @Schema(description = "省份")
    @ExcelProperty("省份")
    private String province;

    @Schema(description = "城市")
    @ExcelProperty("城市")
    private String city;

    @Schema(description = "区域")
    @ExcelProperty("区域")
    private String area;

    @Schema(description = "详细地址")
    @ExcelProperty("详细地址")
    private String detailAddress;

    @Schema(description = "城市地区")
    @ExcelProperty("城市地区")
    private String areaInfo;

    @Schema(description = "下次联系时间")
    @ExcelProperty("下次联系时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime nextTime;

    @Schema(description = "最后跟进时间")
    @ExcelProperty("最后跟进时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime followTime;

    @Schema(description = "领取时间")
    @ExcelProperty("领取时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime collectTime;

    @Schema(description = "跟进状态")
    @ExcelProperty("跟进状态")
    private String followStatus;

    @Schema(description = "腾讯QQ")
    @ExcelProperty("腾讯QQ")
    private String qq;

    @Schema(description = "渠道来源")
    @ExcelProperty("渠道来源")
    private String channelSource;

    @Schema(description = "性别")
    @ExcelProperty("性别")
    private String sex;

    @Schema(description = "年龄")
    @ExcelProperty("年龄")
    private String age;

    @Schema(description = "婚姻状况")
    @ExcelProperty("婚姻状况")
    private String married;

    @Schema(description = "学历")
    @ExcelProperty("学历")
    private String education;

    @Schema(description = "身高")
    @ExcelProperty("身高")
    private Double height;

    @Schema(description = "体重")
    @ExcelProperty("体重")
    private Double weight;

    @Schema(description = "备注（大字段）")
    @ExcelProperty("备注（大字段）")
    private String remarks;

    @Schema(description = "收入")
    @ExcelProperty("收入")
    private String income;

    @Schema(description = "注册时间")
    @ExcelProperty("注册时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime registerTime;

    @Schema(description = "分配时间")
    @ExcelProperty("分配时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime assignTime;

    @Schema(description = "跟进记录")
    @ExcelProperty("跟进记录")
    private String followRecords;

    @Schema(description = "用户名")
    @ExcelProperty("用户名")
    private String userName;

    @Schema(description = "成交状态")
    @ExcelProperty("成交状态")
    private String dealStatus;

    @Schema(description = "线索级别")
    @ExcelProperty("线索级别")
    private String cluesLevel;

    @Schema(description = "微信")
    @ExcelProperty("微信")
    private String wechat;

    @Schema(description = "创建时间")
    @ExcelProperty("创建时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime createTime;

    @Schema(description = "更新时间")
    @ExcelProperty("更新时间")
    @DateTimeFormat("yyyy-MM-dd HH:mm:ss")
    private LocalDateTime updateTime;

    @Schema(description = "创建者")
    @ExcelProperty("创建者")
    private String creator;

    @Schema(description = "更新者")
    @ExcelProperty("更新者")
    private String updater;

    @Schema(description = "出生年份")
    @ExcelProperty("出生年份")
    private String birthYear;

    // 用于动态列导出的辅助字段
    private Set<String> selectedColumns;
}